package com.damai.action.json;

import java.io.IOException;
import java.util.Map;

import javax.servlet.http.HttpServletRequest;

import com.citywithincity.utils.JsonUtil;
import com.damai.action.NoinputError;

class DefGetJson implements IGetJson {

	@Override
	public Map<String, Object> getJson(HttpServletRequest request) throws IOException {
		try{
			return JsonUtil.read(request.getInputStream());
		}catch(IOException e){
			throw new NoinputError();
		}
		
	}

}
